<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <meta name="Keywords" content="" />
        <meta name="Description" content="" />
        <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />
        <title>{$goods['goods_title']}_淘嘟嘟</title>
        <link rel="shortcut icon" href="favicon.ico" />
        <link rel="icon" href="animated_favicon.gif" type="image/gif" />
        <link rel="stylesheet" type="text/css" href="__CSS__/home/goods.css" />
        <link rel="stylesheet" type="text/css" href="__CSS__/home/68ecshop_common.css" />
        <link rel="stylesheet" type="text/css" href="__CSS__/colorbox.css" />
        <link rel="stylesheet" type="text/css" href="__CSS__/mobile/com/font-awesome.css"/>
	<script src="__JQ__" type="text/javascript" charset="utf-8"></script>
        <script src="__JS__/taodudu.lib.js" type="text/javascript" charset="utf-8"></script>
        <script src="__JS__/jquery.colorbox-min.js" type="text/javascript" charset="utf-8"></script>
        <script type="text/javascript" src="__JS__/DataLazyLoad.js"></script>
        <!--二维码生成-->
        <script src="http://apps.bdimg.com/libs/jquery-qrcode/1.0.0/jquery.qrcode.min.js" type="text/javascript"></script>
        <script type="text/javascript">
        	var $200=$;
            $(document).ready(function () {
                $200("#phone").qrcode({
                    render: "canvas",
                    width: 120,
                    height: 120,
                    text: "{:WEIXIN_URL}/Goods/{$goods['goods_id']}"
                });
                $200("#ghs").qrcode({
                    render: "canvas",
                    width: 120,
                    height: 120,
                    text: "{:WEIXIN_URL}/Supplier/{$goods['store_id']}"
                });
            });
        </script>
        <!--生成结束-->
        <script type="text/javascript" src="__JS__/layer/layer.js"></script>
        <!--分享-->
        <script src="__JS__/home/share.js" type="text/javascript" charset="utf-8"></script>
    </head>

    <body style="cursor: auto;">
        <include file="Public/head_a" />
        <include file="Public/head_b" />
        <include file="Public/head_c" />
        <!--全部商品结束-->
        <div class="margin-w1210 clearfix">
            <!--地图-->
            <div id="map_goods" class="w">
                <div class="breadcrumb clearfix">
                    <a href="{:HOME_URL}" class="index">首页</a> <span class="crumbs-arrow">&gt;</span>
                    <div class="crumbs-nav crumbs-nav0">
                        <a class="crumbs-title" href="{:HOME_URL}/Cate/tdd{$goods['goods_class1']}">{$class1_name1}<i class="icon"></i></a>
                        <div class="crumbs-drop">
                            <ul class="crumbs-drop-list">
                                <foreach item='v' name='class1'>
                                    <li><a href="{:HOME_URL}/Cate/tdd{$v['cat_id']}">{$v['cat_name']}</a></li>
                                </foreach>
                            </ul>
                        </div>
                    </div> <span class="crumbs-arrow">&gt;</span>
                    <div class="crumbs-nav crumbs-nav1">
                        <a class="crumbs-title" href="{:HOME_URL}/Cate/tdd{$goods['goods_class2']}">{$class1_name2}<i class="icon"></i></a>
                        <div class="crumbs-drop">
                            <ul class="crumbs-drop-list">
                                <foreach item='v' name='class2'>
                                    <li><a href="{:HOME_URL}/Cate/tdd{$v['cat_id']}">{$v['cat_name']}</a></li>
                                </foreach>
                            </ul>
                        </div>
                    </div> <span class="crumbs-arrow">&gt;</span>
                    <div class="crumbs-nav crumbs-nav2">
                        <a class="crumbs-title" href="{:HOME_URL}/Cate/tdd{$goods['goods_class3']}">{$class1_name3}<i class="icon"></i></a>
                        <div class="crumbs-drop">
                            <ul class="crumbs-drop-list">
                                <foreach item='v' name='class3'>
                                    <li><a href="{:HOME_URL}/Cate/tdd{$v['cat_id']}">{$v['cat_name']}</a></li>
                                </foreach>
                            </ul>
                        </div>
                    </div> <span class="crumbs-arrow">&gt;</span> <span class="last">{$goods['goods_title']}</span>
                </div>
            </div>
            <!--地图结束-->
            <div class="blank"></div>
            <script>
            $(function () {
                $('.breadcrumb .crumbs-nav').hover(function () {
                    $(this).toggleClass('curr');
                })
            })
            </script>
            <div id="product-intro" class="goods-info">
                <!--放大镜-->
                <div id="preview">
                    <div class="goods-img" id="li_17297">
                        <a href="{$goods['images'][0]}" class="MagicZoom" id="zoom" rel="zoom-position: right;" title="" style="position: relative; display: inline-block; text-decoration: none; outline: 0px; width: 400px;">
                            <img src="{$goods['images'][0]}" class="goodsimg pic_img_17297" id="goods_bimg" width="400" height="400" style="opacity: 1;">
                                <div class="MagicZoomBigImageCont" style="overflow: hidden; z-index: 100; top: -100000px; position: absolute; width: 400px; height: 400px; opacity: 1; left: 415px;">
                                    <div class="MagicZoomHeader" style="position: relative; z-index: 10; left: 0px; top: 0px; padding: 3px; display: none; visibility: hidden;"></div>
                                    <div style="overflow: hidden;"><img src="http://img.taodudu.com/upload/store/597/562/201512251708236124.jpg" style="padding: 0px; margin: 0px; border: 0px; position: relative; left: -11.4px; top: -15px;"></div>
                                </div>
                                <div class="MagicZoomPup" style="z-index: 10; position: absolute; overflow: hidden; display: none; visibility: hidden; width: 384px; height: 384px; opacity: 0.5; left: 5.5px; top: 14px;"></div>
                        </a>
                    </div>
                    <div style="height:10px; line-height:10px; clear:both;"></div>

                    <div class="clearfix">
                        <span class="scrleft" onmouseover="moveLeft()" onmousedown="clickLeft()" onmouseup="moveLeft()" onmouseout="scrollStop()"></span>
                        <div class="gallery">
                            <div id="demo" style="width: 720px;">
                                <div id="demo1" style="float: left; width: 120px;">
                                    <ul id="goods_gallery">
                                        <foreach name="goods['images']" item="vo" key="k">
                                            <li  onclick="showPic({$k})" rel="MagicZoom"><img src="{$vo}" tsimgs="{$vo}"></li>
                                        </foreach>
                                    </ul>
                                </div>
                                <div id="demo2" style="display: inline; overflow: visible; width: 120px;"></div>
                            </div>
                        </div>
                        <span class="scrright" onmouseover="moveRight()" onmousedown="clickRight()" onmouseup="moveRight()" onmouseout="scrollStop()"></span>
                        <script>
                            function $gg(id) {
                                return(document.getElementById) ? document.getElementById(id) : document.all[id]
                            }

                            var boxwidth = 60; //跟图片的实际尺寸相符

                            var box = $gg("demo");
                            var obox = $gg("demo1");
                            var dulbox = $gg("demo2");
                            obox.style.width = obox.getElementsByTagName("li").length * boxwidth + 'px';
                            dulbox.style.width = obox.getElementsByTagName("li").length * boxwidth + 'px';
                            box.style.width = obox.getElementsByTagName("li").length * boxwidth * 6 + 'px';
                            var canroll = false;
                            if (obox.getElementsByTagName("li").length >= 6) {
                                canroll = true;
                                dulbox.innerHTML = obox.innerHTML;
                            }
                            var step = 5;
                            temp = 1;
                            speed = 50;
                            var awidth = obox.offsetWidth;
                            var mData = 0;
                            var isStop = 1;
                            var dir = 1;

                            function s() {
                                if (!canroll)
                                    return;
                                if (dir) {
                                    if ((awidth + mData) >= 0) {
                                        mData = mData - step;
                                    } else {
                                        mData = -step;
                                    }
                                } else {
                                    if (mData >= 0) {
                                        mData = -awidth;
                                    } else {
                                        mData += step;
                                    }
                                }

                                obox.style.marginLeft = mData + "px";

                                if (isStop)
                                    return;

                                setTimeout(s, speed)
                            }

                            function moveLeft() {
                                var wasStop = isStop;
                                dir = 1;
                                speed = 50;
                                isStop = 0;
                                if (wasStop) {
                                    setTimeout(s, speed);
                                }
                            }

                            function moveRight() {
                                var wasStop = isStop;
                                dir = 0;
                                speed = 50;
                                isStop = 0;
                                if (wasStop) {
                                    setTimeout(s, speed);
                                }
                            }

                            function scrollStop() {
                                isStop = 1;
                            }

                            function clickLeft() {
                                var wasStop = isStop;
                                dir = 1;
                                speed = 25;
                                isStop = 0;
                                if (wasStop) {
                                    setTimeout(s, speed);
                                }
                            }

                            function clickRight() {
                                var wasStop = isStop;
                                dir = 0;
                                speed = 25;
                                isStop = 0;
                                if (wasStop) {
                                    setTimeout(s, speed);
                                }
                            }
                        </script>
                    </div>
                    <div class="goods-gallery-bottom">
                        <a onclick="favorites({$goods['goods_id']},20,2)" class="goods-col fr">
                            <if condition="$goods_fa neq 0">
                                <b class="guanzhu_bj{$goods['goods_id']} on"></b><i class="guanzhu_txt_num{$goods['goods_id']}">已收藏 ({$goods['num'] ? $goods['num'] : 0})</i>
                            <else />
                                <b class="guanzhu_bj{$goods['goods_id']}"></b><i class="guanzhu_txt_num{$goods['goods_id']}">收藏 ({$goods['num'] ? $goods['num'] : 0})</i>
                            </if>
                        </a>
                        <div class="bdsharebuttonbox fr bdshare-button-style0-16" data-bd-bind="1476756467475">
                            <a class="bds_more" href="#" data-cmd="more" style="background: transparent url(/Public/img/home/goods-icon.png) no-repeat -110px -166px;color: #999;line-height: 25px;height: 25px; margin: 0px 10px; padding-left:20px; display: block;">分享</a>
                        </div>
                    </div>
                </div>
                <!--放大镜结束-->
                <div class="goods-detail-info">
                    <form action="{:U('/Trader/nowbuy')}" method="post" name="ECS_FORMBUY" id="ECS_FORMBUY">
                        <div class="goods-name">
                            <h1>{$goods['goods_title']}</h1>
                        </div>
                        <div class="goods-brief"><span>{$goods['goods_buytitle']}</span></div>
                        <div id="goods-price">
                            
                            <div class="mar-l">
                                <span class="price">售价</span><strong class="p-price" id="ECS_GOODS_AMOUNT">￥{$goods['goods_price']}</strong>
                                <span class="depreciate"><a href="#">降价通知</a></span>
                            </div>
                            
                            <div class="show-price">
                                <div class="market-prices-spe">
                                    <span class="price">市场价</span>
                                    <font class="market-price">￥{$goods['goods_markprice']}</font>
                                </div>
                            </div>
                            <ul id="list1" style="width:100%;">
                                <li id="summary-stock">
                                    <div class="dt">配送：&nbsp;{$store['area_info']}&nbsp;至：</div>
                                    <div class="dd">
                                        <div id="store-selector">
                                            <div class="text"><div></div><b></b></div>                   
                                            <div onclick="$('#store-selector').removeClass('hover')" class="close"></div>
                                        </div><!--store-selector end-->
                                        <div id="store-prompt"><strong></strong></div><!--store-prompt end--->
                                    </div>
                                </li>
                                <li id="good_freight">快递费：免运费</li>
                            </ul>
                        </div>
                        <div id="summary-qita">
                            <ul class="qita">
                                <li>
                                    <p>累积销售：<span><a href="#">{$goods['goods_hits']}件</a></span></p>
                                </li>
                                <li style=" display:none">
                                    <p>累计销量<span>0</span></p>
                                </li>
                                <li style="border:none">
                                    <p>赠送积分：<span><font id="ECS_GOODS_AMOUNT_jf">{$goods['goods_price']|round}</font></span></p>
                                </li>
                            </ul>
                        </div>
                        <ul id="choose" class="choose_bor">
                            <foreach item='v' name='attri' key="k">
                                <li id="choose-version">
                                    <div class="dt">{$v['guige']}</div>
                                    <div class="dd">
                                        <ul class="ys_xuan">
                                            <div class="catt" data-sid="{$k}">
                                                <input type="hidden" name="guige{$k+1}" id="guige{$k+1}" value="" />
                                                <foreach item='m' name="v.class">
                                                    <a data-aid="{$m['aid']}">
                                                        <div class="value-label">{$m['name']}</div>
                                                    </a>
                                                </foreach>
                                            </div>
                                        </ul>
                                    </div>
                                </li>
                            </foreach>

                            <li id="choose-amount">
                                <div class="dt">数量</div>
                                <div class="dd">
                                    <div class="wrap-input">
                                        <script language="javascript" type="text/javascript">
                                            function goods_cut() {
                                                var num_val = document.getElementById('number');
                                                var new_num = num_val.value;
                                                var Num = parseInt(new_num);
                                                if (Num > 1)
                                                    Num = Num - 1;
                                                num_val.value = Num;
                                                changePrice();
                                            }

                                            function goods_add() {
                                                var num_val = document.getElementById('number');
                                                var new_num = num_val.value;
                                                var Num = parseInt(new_num);
                                                Num = Num + 1;
                                                num_val.value = Num;
                                                changePrice();
                                            }

                                            function changePrice() {
                                                if (Number($("#number").attr("data-stock")) < Number($("#number").val())) {
                                                    $("#number").val($("#number").attr("data-stock"));
                                                }
                                                if(Number($("#number").val())<=0){
                                                	$("#number").val(1);
                                                }
                                            };
                                        </script>
                                        <if condition="$goods['goods_stock'] eq 0">
                                            <a class="btn-reduce">减少数量</a>
                                            <input name="number" data-stock="{$goods['goods_stock']}" type="text" class="text" id="number" value="0" onblur="changePrice();">
                                            <a class="btn-add">增加数量</a>
                                            &nbsp;&nbsp;无货
                                            <else />
                                            <a class="btn-reduce" onclick="goods_cut()">减少数量</a>
                                            <input name="number" data-stock="{$goods['goods_stock']}" type="text" class="text" id="number" value="1" onblur="changePrice();">
                                            <a class="btn-add" onclick="goods_add();">增加数量</a>
                                            &nbsp;&nbsp;有货
                                        </if>
                                    </div>
                                </div>
                            </li>
                        </ul>
                        <div class="buyNub-buy-wrap">
                            <div id="choose-btns1" class="buyNub-buy" style="display:none">
                                <a class="tell-me"><i></i>到货通知</a>
                            </div>
                            
                            <if condition="($goods['goods_sale'] eq 1) and ($goods['goods_state'] eq 1)">
                            <div id="choose-btns" class="buyNub-buy" style="display: block;">
                                <!-- 立即购买-->
                                <a class="u-buy1" title="立即购买">立即购买</a>
                                <!-- 加入购物车-->
                                <a class="u-buy2" title="添加购物车"><i class="icon-shopping-cart"></i>添加购物车</a>
                                <input type="hidden" name="goods_id" value="{$goods['goods_id']}" />
                                <input id="goods_transport" type="hidden" name="transport_id" value="{$goods['transport_id']}" />
                                <a id="phone" class="btn-phone" style="position:relative;cursor:pointer">
                                    <i></i>手机扫码购买
                                    <b class="jiao"></b>
                                    <div id="phone"></div>
                                </a>
                            </div>
                            <else />
                            <div id="choose-btns" class="buyNub-buy" style="display: block;">
                                <a class="u-buy3" title="此商品已售罄">此商品已售罄</a>
                            </div>
                            </if>
                            
                            
                            <script type="text/javascript">
                                $("#phone").mouseover(function () {
                                    $("#phone").animate({
                                        height: '180px'
                                    }, {
                                        duration: 300,
                                        queue: false
                                    });
                                });
                                $("#phone").mouseleave(function () {
                                    $("#phone").animate({
                                        height: '38px'
                                    }, {
                                        duration: 300,
                                        queue: false
                                    });
                                });
                            </script>
                        </div>
                    </form>
                </div>
                <div id="supp_info">

                    <div id="shop-info">
                        <dl class="shop-title">
                            <dt>
                                <a href="{:HOME_URL}/Supplier/{$goods['store_id']}" target="_blank">{$store['store_name']}</a>
                            </dt>
                        </dl>
                        <div class="blank"></div>
                        <div class="shop-info-detail">
                            <dl class="rate-detail">
                                <dt>好&nbsp;评&nbsp;率&nbsp;：</dt>
                                <dd><span class="hot-grey"><span class="hot-red" style="width:100%;"></span></span>100%</dd>
                            </dl>
                            <dl style="padding-top:10px;">
                                <dt>公司名称：</dt>
                                <dd title="{$store['store_company_name']}">{$store['store_company_name']|sub_str=###,0,9}</dd>
                            </dl>
                            <dl>
                                <dt>商店等级：</dt>
                                <dd>中级店铺</dd>
                            </dl>
                            <dl>
                                <dt>客服 QQ：</dt>
                                <dd>
                                    <a href="tencent://message/?uin=2734780971&Site=&menu=yes"><img src="http://wpa.qq.com/pa?p=1:2734780971:4" height="16" border="0" alt="QQ"></a>
                                </dd>
                            </dl>
                            <dl>
                                <dt>客服电话：</dt>
                                <dd>400-0371-775</dd>
                            </dl>
                            <dl>
                                <dt>所在地区：</dt>
                                <dd>{$store['area_info']}</dd>
                            </dl>

                            <ul class="score-detail">
                                <li>
                                    <a title="描述5.0"> <span class="score-tit score-tit1">描述</span><span class="scores">{:empty($branch['miaoshu']) ? '5.0' : $branch['miaoshu']}</span> </a>
                                </li>
                                <li>
                                    <a title="服务5.0"> <span class="score-tit score-tit2">服务</span><span class="scores">{:empty($branch['fuwu']) ? '5.0' : $branch['fuwu']}</span> </a>
                                </li>
                                <li style="margin-right: 0px">
                                    <a title="物流5.0"> <span class="score-tit score-tit3">物流</span><span class="scores">{:empty($branch['wuliu']) ? '5.0' : $branch['wuliu']}</span> </a>
                                </li>
                            </ul>
                            <div id="enter-shop">
                                <div class="enter-shop-item">
                                    <a class="btn-flat1 goto-shop" href="{:HOME_URL}/Supplier/{$goods['store_id']}" target="_blank"><i></i>进入商店 </a>
                                    <a class="btn-flat1 shop-add quick-dian" onclick="favorites({$goods['store_id']},40,1)">
                                    	<i></i>
                                    	<span class="guanzhu_txt_num{$goods['store_id']}">
                                    		<if condition="$user_num neq 0">
                                    			已关注
                                    		<else />
                                    			关注本店	
                                    		</if>
                                    	</span>
                                    </a>
                                </div>
                                <div id="attention-shop">
                                    <p>扫一扫，手机访问店铺</p>
                                    <div id="ghs"></div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="goods-best">
                <div class="mt">
                    <h2>店铺更多精品</h2>
                </div>
                <div class="colList">
                    <a id="btn-left1" class="prev" title="上一个"></a>
                    <div class="colFrame">
                        <ul>
                            <foreach item="v" name="datawww">
                                <li>
                                    <div class="p-img">
                                        <a href="{:HOME_URL}/Goods/{$v['goods_id']}" title="{$v['goods_title']}"><img width="160" height="160" alt="{$v['goods_title']}" src="__IMG__/grey.gif" data-img ="{$v['goods_thumb']}" isload="false"></a>
                                    </div>
                                    <div class="rain-product-info">
                                        <div class="p-price"><strong class="best_goods_price">￥{$v['goods_price']} </strong></div>
                                        <div class="rate"><a href="{:HOME_URL}/Goods/{$v['goods_id']}" title="{$v['goods_title']}">{$v['goods_title']}</a></div>
                                    </div>
                                </li>
                            </foreach>
                        </ul>
                    </div>
                    <a id="btn-right1" class="next" title="下一个"></a>
                </div>
                <script type="text/javascript">
                    //图片大图浏览
                    window.onload=function(){
                        $(".pic-thumbnail").colorbox({rel:'pic-thumbnail',width:"600px"});
                    }
                </script>
            </div>
            <div class="left-con">
                <div class="aside-con aside-con1">
                    <div class="aside-tit">
                        <h2>相关分类</h2>
                    </div>
                    <div class="aside-list">
                        <ul>
                            <foreach item='v' name='class3'>
                                <li><a href="{:HOME_URL}/Cate/tdd{$v['cat_id']}" target="_blank">{$v['cat_name']}</a></li>
                            </foreach>
                        </ul>
                    </div>
                </div>
                <div class="aside-con collect">
                    <div class="aside-tit">
                        <h2>同类品牌</h2>
                    </div>
                    <div class="aside-list colList">
                        <div class="slider colFrame" id="slider">
                            <ul>
                                <notempty name='classGoods'>
                                    <foreach item="v" name="classGoods">
                                        <li>
                                            <div class="p-img">
                                                <a href="{:HOME_URL}/Goods/{$v['goods_id']}"><img width="200" height="180" alt="{$v['goods_title']}" src="__IMG__/grey.gif" data-img ="{$v['goods_thumb']}" isload="false"></a>
                                            </div>
                                            <div class="rate">
                                                <a href="{:HOME_URL}/Goods/{$v['goods_id']}" title="{$v['goods_title']}">{$v['goods_title']}</a>
                                            </div>
                                            <div class="p-price"><strong>￥{$v['goods_price']}</strong></div>
                                        </li>
                                    </foreach>
                                    <else />
                                    <li>暂无同类商品！</li>
                                </notempty>
                            </ul>
                        </div>
                    </div>
                </div>
                <div class="aside-con collect">
                    <div class="aside-tit">
                        <h2>最近上新</h2>
                    </div>
                    <div class="aside-list colList">
                        <div class="slider colFrame" id="slider">
                            <ul>
                                <notempty name='newGoods'>
                                    <foreach item="v" name="newGoods">
                                        <li>
                                            <div class="p-img">
                                                <a href="{:HOME_URL}/Goods/{$v['goods_id']}"><img width="200" height="180" alt="{$v['goods_title']}" src="__IMG__/grey.gif" data-img ="{$v['goods_thumb']}" isload="false"></a>
                                            </div>
                                            <div class="rate">
                                                <a href="{:HOME_URL}/Goods/{$v['goods_id']}" title="{$v['goods_title']}">{$v['goods_title']}</a>
                                            </div>
                                            <div class="p-price"><strong>￥{$v['goods_price']}</strong></div>
                                        </li>
                                    </foreach>
                                    <else />
                                    <li>暂无上传新的商品！</li>
                                </notempty>
                            </ul>
                        </div>
                    </div>
                </div>

                <div class="blank"></div>

            </div>
            <div class="right-con" style="overflow: visible;">
                <div id="wrapper">
                    <div class="mt" id="main-nav-holder">
                        <ul class="tab" id="nav">
                            <li class="boldtit-list h-list">
                                <a data-href="os_canshu" onclick="move_huan($(this))">规格参数</a>
                            </li>
                            <li class="boldtit-list">
                                <a data-href="os_jieshao" onclick="move_huan($(this))">商品介绍</a>
                            </li>
                            <li class="boldtit-list">
                                <a data-href="os_pinglun" onclick="move_huan($(this))">商品评价(0)</a>
                            </li>
                            <li class="boldtit-list">
                                <a data-href="os_zixun" onclick="move_huan($(this))">咨询提问</a>
                            </li>
                            <li class="boldtit-list">
                                <a data-href="os_shouhou" onclick="move_huan($(this))">售后保障</a>
                            </li>
                        </ul>
                        <div class="goods-ce-right">
                            <a href="#" name="bi_addToCart" class="right-add">加入购物车</a>
                            <div class="ce-right">
                                <ul class="abs-ul">
                                    <li class="abs-active">
                                        <a data-href="os_canshu" onclick="move_huan($(this))"><i></i><span>规格参数</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_jieshao" onclick="move_huan($(this))"><i></i><span>商品介绍</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_pinglun" onclick="move_huan($(this))"><i></i><span>商品评价</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_zixun" onclick="move_huan($(this))"><i></i><span>咨询提问</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_tiwen" onclick="move_huan($(this))"><i></i><span>我要咨询</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_shouhou" onclick="move_huan($(this))"><i></i><span>售后服务</span></a>
                                    </li>
                                    <li>
                                        <a data-href="os_changjian" onclick="move_huan($(this))"><i></i><span>常见问题</span></a>
                                    </li>
                                </ul>
                            </div>
                        </div>
                    </div>
                    <div id="main_widget_1">
                        <div class="mc" id="os_canshu">
                            <ul class="detail-list">
                                <foreach item='v' name='spec'>
                                    <li>{$v['paraname']}：{$v['value']}</li>
                                </foreach>
                            </ul>
                        </div>
                        <div class="mc" id="os_jieshao">
                            <div class="blank20"></div>
                            <div class="detail-content">
                                {$goods['goods_content']}
                            </div>
                        </div>
                        <div class="mc" id="os_pinglun">
                            <div class="blank20"></div>
                            <div class="my-comment-pre">
                                <div class="tab-title">
                                    <span>商品评价</span>
                                </div>
                                <div class="goods-content">
                                    <ul>
                                        <li class="hpd">
                                            <div class="main-color">100%</div>
                                            <p>好评度</p>
                                        </li>
                                        <li class="pre">
                                            <dl><dt>好评<span>(100%)</span></dt>
                                                <dd>
                                                    <div style="width:100%"></div>
                                                </dd>
                                            </dl>
                                            <dl><dt>中评<span>(100%)</span></dt>
                                                <dd>
                                                    <div style="width:100%"></div>
                                                </dd>
                                            </dl>
                                            <dl><dt>差评<span>(100%)</span></dt>
                                                <dd>
                                                    <div style="width:100%"></div>
                                                </dd>
                                            </dl>
                                        </li>
                                    </ul>
                                </div>
                            </div>
                            <div class="my-comment-tab">
                                <ul>
                                    <li id="mct_0" class="cur">全部评价<span>(0)</span></li>
                                    <!--<li id="mct_1">好评<span>(0)</span></li>
                                    <li id="mct_2">中评<span>(0)</span></li>
                                    <li id="mct_3">差评<span>(0)</span></li>
                                    <li id="mct_4">用户晒单<span>(0)</span></li>-->
                                </ul>
                            </div>
                            <div class="my-comment-list" id="ECS_MYCOMMENTS">
                                <!-- 提取商品评价 -->
                                <script type="text/javascript">
                                    $(document).ready(function () {
                                        $.post("{:U('goodsComment')}", {goods_id: {$goods['goods_id']}}, function (result) {
                                            $("#ECS_MYCOMMENTS").html(result['html']);
                                            $("#mct_0 > span").html('('+result['count']+')');
                                            $("#nav > li:nth-child(3) > a").html('商品评价('+result['count']+')');
                                        });
                                    })
                                </script>
                            </div>
                        </div>
                        <!--商品咨询on-->
                        <div class="mc" id="product_consult_init" style="display: block; margin-top: 10px;margin-bottom: 10px;">
							<div class="mod" id="os_zixun">
								<div class="mod-title"><h2 class="order-box-title">商品咨询</h2></div>
								<div class="consult-title">
                                    <a href="#zixun" class="btn btn-red-bu"><span>我要咨询</span></a>
								</div>
								<div class="consult-content" id="consult_content_init">
									<div class="action-content-list switchable-panel">

                                        <if condition="$advice">
										    <ul class="consult-list">
                                            <foreach name="advice" item="v">
										    	<li class="consult-item">
										    		<span class="icon icon-question fa fa-question-circle"></span>
										    		<p class="question-content clearfix">
										    			<span class="desc"><b>问：</b>{$v['question']}</span>
										    			<span class="name" style="padding:5px;">{$v['user_name']|substr_cut}</span><span class="time">{$v['addtime']|date="y-m-d H:i:s",###}</span>
										    		</p>
										    		<!-- 回答列表 -->
                                                    <if condition="$v.reply neq null">
										    		<div class="answer-list action-reply">
										    			<span class="icon icon-answer fa fa-list-alt"></span>
										    			<input type="hidden" name="id" value="25649">
										    			<blockquote class="answer-item answer-admin">
										    				<em class="icon lquote fa fa-angle-double-right"></em>
										    				<div class="clearfix"><span class="infos"><em>客服</em> 回复</span><span class="time">{$v['gtime']|date="y-m-d H:i:s",###}</span></div>
										    				<p class="answer-content"></p>
										    				<p>{$v['reply']}</p>
										    				<p></p>
										    				<em class="icon rquote fa fa-angle-double-left"></em>
										    			</blockquote>
										    		</div>
                                                    </if>
										    	</li>
                                            </foreach>
										    </ul>
                                        <else/>
                                            <div style="text-align: center;padding: 20px 0px;border: 1px #ddd solid;color: #f60;font-size: 14px;">暂时还没有用户提问！</div>
                                       </if>
									</div>

									<div class="title title-aside" style="padding:5px;">
									</div>
								</div>
								<div class="mini-pageview">
									{$page}
								</div>
							</div>
						</div>
						<div class="mc mod post-comment" style="margin-bottom: 10px;" id="post_consult">
						  <div class="mod-title" id="os_tiwen">
						    <h2 class="order-box-title">发表咨询</h2>
						  </div>
						  <div class="mod-content">
						    <form action="" method="post" id="advice" class="action-code-form" onsubmit="return tw()">
                                <input type="hidden" name="goods_id" value="{$goods['goods_id']}">
                                <input type="hidden" name="goods_name" value="{$goods['goods_title']}">
						      <ul>
						        <li class="form-item">
						            <div class="sub-label-side"></div>
						            <div class="form-act-side">
						              <textarea class="action-filled-textarea" vtype="required" name="question" id="comment" cols="20" rows="10" placeholder="欢迎发表咨询，最多1000字。"></textarea>
						                        <div class="clearfix">
						                <div class="sub-label"></div>
						              </div>
						            </div>
						        </li>
						        <li class="form-item form-item-last">
						        <span class="form-act">
                                    <input type="submit" class="btn btn-red-bu" value="提交评论">
						        	</span>
						        </li>
						      </ul>
						    </form>
						  </div>
						</div>
                        <!--商品咨询off-->
                        <div class="mc" id="os_shouhou">
                            <div class="sure">
                                <div class="tite">
                                    <h3 style="width:220px;">淘嘟嘟优质的售后保障服务</h3>
                                </div>
                                <div class="box">
                                    <div class="security">
                                        <div>
                                            <img src="__IMG__/home/security_one.jpg">
                                                <h4>电话服务</h4>
                                                <p class="dianhua">400-0371-775</p>
                                                <p class="tis1">24小时贴心服务</p>
                                        </div>
                                        <div class="xian"></div>
                                        <div>
                                            <img src="__IMG__/home/security_two.jpg">
                                                <h4>在线客服</h4>
                                                <a href="#" class="xl_btn">点击这里联系</a>
                                                <p class="tis1">周一至周日8:30-18:00</p>
                                        </div>
                                        <div class="xian"></div>
                                        <div style="width:217px;">
                                            <img src="__IMG__/home/security_three.jpg">
                                                <h4>售后服务</h4>
                                                <p style="margin-top:12px;">您可以在
                                                    <a href="#">我的淘嘟嘟-已完成订单中</a>
                                                </p>
                                                <p>选择需要售后的订单或商品</p>
                                                <p>我们客服将第一时间与您联系</p>
                                        </div>
                                    </div>
                                    <div class="clear"></div>
                                </div>

                            </div>
                        </div>
                        <div class="mc" id="os_changjian">
                            <div class="blank20"></div>
                            <div class="sure">
                                <div class="tite">
                                    <h3>告消费者须知</h3>
                                </div>
                                <div class="box">
                                    <div class="says">
                                        <span style="margin-bottom:66px;">1</span>
                                        <span style="margin-bottom:63px;">2</span>
                                        <span style="margin-bottom:63px;">3</span>
                                        <span style="margin-bottom:38px;">4</span>
                                        <span>+</span>
                                    </div>
                                    <ul class="text">
                                        <li>淘嘟嘟是郑州报业集团旗下网购生活平台，淘嘟嘟网站所售产品均为正品，入驻商家均为企业店铺，如有任何问题可与我们客服人员联系，我们会在第一时间跟您沟通处理。</li>
                                        <li>消费者收到货品后，开箱验货如存在包装破损等影响签收的因素，请您可以拒收全部商品（包括赠品）；为了保护您的权益，建议您尽量不要委托他人代为签收；如由他人代为签收商品 而没有在配送人员在场的情况下验货，则视为您所订购商品的包装无任何问题。</li>
                                        <li>本商城承诺七天无理由退换货，如属质量问题，退换货过程中产生的运费用由卖家承担，非质量问题的退货，请在收到宝贝后七天内与联系客服进行退换货操作，运费买家承担。</li>
                                        <li>本商城上的所有商品信息、客户评价、商品咨询、网友讨论等内容，是淘嘟嘟商城重要的经营资源，未经许可，禁止非法转载使用。</li>
                                        <li>本站商品信息均来自于商家提供，其真实性、准确性和合法性由商家负责。本站不提供任何保证，并不承担任何法律责任。</li>
                                    </ul>
                                    <div class="clear"></div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <!--公共底部-->
        <div style="clear: both"></div>
        <div class="site-footer">
            <div class="footer-related">
                <include file="Public/bootom_a" />
                <include file="Public/bootom_b" />
                <include file="Public/bootom_c" />
                <include file="Public/cart" />
            </div>
        </div>
    </body>

</html>
<script type="text/javascript">
    $('#advice').layer({});

    $(window).scroll(function () {
        //侧导航浮动
        var offsetTop = $(window).scrollTop();
        var winheight = $(window).height();
        if (offsetTop - $("#wrapper").offset().top + 100 > 0) {
            $('.goods-ce-right').animate({
                top: offsetTop - $("#wrapper").offset().top + 100
            }, {
                duration: 700,
                queue: false
            });
        } else {
            $('.goods-ce-right').animate({
                top: 0
            }, {
                duration: 700,
                queue: false
            })
        }
        //侧导航精准定位
        var objindex = 0;
        $("#main_widget_1 > .mc").each(function () {
            if (offsetTop + winheight / 2 > $(this).offset().top) {
                objindex = $(this).index();
            }
        })
        $('.abs-ul li').eq(objindex).addClass("abs-active").siblings().removeClass("abs-active");
        //侧导航精准定位结束
    }) //滚动事件结束
    //锚点缓动
    function move_huan(_this){
		 $('body,html').animate({
			'scrollTop':$("#"+_this.data("href")).offset().top
		})
    }
    //提问判断
    function tw(){
        //判断是否登陆
        if (!Sign()) {
            return false;
        }
        //文字是否超出限制
        var len = $("#comment").val().length;
        if(len>1000){
            layer.msg('文字超出长度限制');
            return false;
        }else if(len==0){
            layer.msg('您好没有提问任何内容');
            return false;
        }
        if(checkQuote($("#comment").val())){
            layer.msg('存在不合法字符');
            return false;
        }
        return true;
    }
</script>
<script>
function isSstock(){
    var a = $('#number').attr('data-stock');
    if(a == 0){
        return false;
    }else{
        return true;
    }
}

function Specifications() { //选择规格是否满足
    var i = 0;
    var o = $("#choose .catt");
    var d = new Array();
    o.each(function() {
        if ($(this).attr("data-attrval")) {
            i++;
            d["guige" + i] = ($(this).attr("data-attrval"));
        }
    })
    d["num"] = ($("#number").val());
    if (! (o.length == i)) {
        o.eq(0).parents("#choose").addClass("choose_bor_bor");
        return false;
    } else {
        o.eq(0).parents("#choose").removeClass("choose_bor_bor");
        return d;
    }
}
function quickdian(dete) { //关注店铺
    dete = {
        dete: dete
    };
    if (!Sign()) {
        return false;
    }
    if (Aajax("www.taodudu.com", dete)) {
        $(".quick-dian").find("span").text("已关注");
    };
}
$(".u-buy1").click(function() { //立即购买
    if (!Sign()) {
        return false;
    }
    if (!Specifications()) {
        return false;
    }
    if(!isSstock()){
        layer.msg('库存不足！');
        return;
    }
    
    $("#ECS_FORMBUY").submit();
})
$(".u-buy2").click(function() { //加入购物车
    var a;
    if (!Sign()) {
        return false;
    }
    if(!isSstock()){
        layer.msg('库存不足！');
        return;
    }
    if (!Specifications()) {
        return false;
    } else {
        var json = {};
        var s = Specifications();
        for (variable in s) {
            json[variable] = s[variable];
        }
        json["goods_id"] = {$goods['goods_id']};
        a = Aajax("/Trader/addcar", json);
    }
    if (a.p) { //状态
        $(".cart_num").text(a.n); //数量
        result = Aajax("/Trader/reloadCart");
        $(".cart-panel-content").html(result);
        layer.msg('加入成功！');
    }else{
        layer.msg('加入失败！');
    }
})
    //价格json
    var sys_item = {$jsonAttr};

    //商品规格选择
    $(function () {
        $("#choose .catt").each(function () {
            var i = $(this);
            var p = i.find("a");
            p.click(function () {
                if (!!$(this).hasClass("wuxiao")) {
                    return;
                }
                if (!!$(this).hasClass("cattsel")) {
                    $(this).removeClass("cattsel");
                    i.removeAttr("data-attrval");
                } else {
                    $(this).addClass("cattsel").siblings("a").removeClass("cattsel");
                    i.attr("data-attrval", $(this).attr("data-aid"))
                }
                getattrprice() //输出价格
                stock($(this)) //获取库存
                changePrice() //购买数量
            })
        })

        //获取对应属性的价格
        function getattrprice() {
        	var olength=$(".ys_xuan").length;
            var defaultstats = true;
            var _val = '';
            var _resp = {
                mktprice: ".market-price",
                price: ".p-price",
                stock: "#number"
            } //输出对应的class
            $("#choose .catt").each(function () {
                var i = $(this);
                var v = i.attr("data-attrval");
                if (!v) {
                    defaultstats = false;
                } else {
                    _val += _val != "" ? "_" : "";
                    _val += v;
                }
                i.find("input").val(i.attr("data-attrval"));
            })
            if (!!defaultstats) {
                _mktprice = sys_item['sys_attrprice'][_val]['mktprice'];
                _price = sys_item['sys_attrprice'][_val]['price'];
                _stock = sys_item['sys_attrprice'][_val]['stock'];
                Specifications();
            } else {
                if (_val&&olength==1) {
	                _mktprice = sys_item[_val]['mktprice'];
	                _price = sys_item[_val]['price'];
	                _stock = sys_item[_val]['stock'];
            	}else {
                    _mktprice = sys_item['mktprice'];
                    _price = sys_item['price'];
                    _stock = sys_item['stock'];
                }

            }
            //输出价格
            $(_resp.mktprice).text("￥" + _mktprice); ///其中的math.round为截取小数点位数
            $(_resp.price).text("￥" + _price);
            $(_resp.stock).attr("data-stock", _stock);
        }
        //获取库存
        function stock(obj) {
            var a = Number(obj.parent().attr("data-sid")); //获取级数
            var v = $("#choose .catt").eq(a).attr("data-attrval"); //获取选中的规格id
            for (var i = 0; i < $("#choose .catt").length; i++) {
                var _val = ''; //json对象值获取
                if (i != a) {
                    $("#choose .catt").eq(i).find("a").each(function () {
                        $(this).removeClass("wuxiao");
                    })
                    $("#choose .catt").eq(i).find("a").each(function () {
                        var d = $(this).attr("data-aid");
                        switch (a) {
                            case 0:
                                _val = v + "_" + d;
                                break;
                            case 1:
                                _val = d + "_" + v;
                                break;
                        }
                        if (v) {
                            _stock = sys_item['sys_attrprice'][_val]['stock'];
                        }
                        if (_stock == 0) {
                            $(this).addClass("wuxiao");
                        }
                    })
                }
            }
        }
    })
    if($("#choose .catt").length==1){  //初始化规格库存为零样式
    	var g_obj=$("#choose .catt").find("a");
    	g_obj.each(function(){
    		_this=$(this);
    		_stock = sys_item['sys_attrprice'][_this.data("aid")]['stock'];
    		if (_stock == 0) {
                $(this).addClass("wuxiao");
            }
    	})
    }
</script>
<script type="text/javascript">
    //点赞功能
	function ping_zan(goods_id,user_val){
        //判断是否登陆
    	if (!Sign()) {
	        return false;
	    }
	    var ping_zan={};
	    ping_zan.goods_id=goods_id;
	    ping_zan.comment_id=user_val;
	    var id="#ping_zan"+user_val;
        //判断是点赞还是取消
	    if($(id).hasClass("on")){
            ping_zan.pan=0;
	    	$(id).removeClass("on");
	    	$(id).find("b").html($(id).find("b").text()-1);
	    }else{
	    	ping_zan.pan=1;
	    	$(id).addClass("on");
	    	$(id).find("b").html(Number($(id).find("b").text())+1);
	    }
        //执行ajax
        var url = homeUrl+'/Comment/zan';
        Aajax(url,ping_zan);
    }
</script>
<!--地区选择-->
<script src="__JS__/home/location.js" type="text/javascript" charset="utf-8"></script>
<!--放大镜 -->
<script src="__JS__/home/magiczoom.js" type="text/javascript" charset="utf-8"></script>
<!--放大镜结束-->